package coom;


import org.greenrobot.eventbus.EventBus;

import java.io.IOException;

import javax.annotation.Nullable;

import event.LoginEvent;
import okhttp3.Authenticator;
import okhttp3.Response;
import okhttp3.Route;


public class TokenAuthenticator  implements Authenticator {

    @Nullable
    @Override
    public okhttp3.Request authenticate(Route route, Response response) throws IOException {
        EventBus.getDefault().post(new LoginEvent());
        return null;
    }
}
